public class Test3 {
    public static void main(String[] args) {
        int sign = 1;
        double result = 0;
        for(double i = 1; i <= 100; i++){
            result += sign*(1/i);
            sign *= -1;
        }
        System.out.println(result);
    }
}
